import router from "./index";

import { userStore } from "../stores/userStore";
let authStore
router.beforeEach(async (to, from, next) => {
  if (!authStore) authStore = userStore();
  try {
    await authStore.getMapData();
  } catch (error) {
    console.log(error, "errpr");
  }
  next();
});
